package com.elong.qadev.entity;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
/**
 * 
* @ClassName: User
* @Description: TODO(用户账户对应model)
* @author kangchen
* @date 2015年10月2日
*
 */
@Entity
@Table(name = "USER", schema = "ti")
public class User implements java.io.Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	@Override
	public String toString() {
		return "User [id=" + id + ", name=" + name + ", password=" + password
				+ ", mail=" + mail + ", phoneNumber=" + phoneNumber
				+ ", createdatetime=" + createdatetime + ", modifydatetime="
				+ modifydatetime + ", remarks=" + remarks + "]";
	}
	public int id;
	public String name;
	public String password;
	public String mail;
	public String phoneNumber;
	private Date createdatetime;
    private Date modifydatetime;
    private String remarks;
    @Column(name = "REMARKS",nullable = true, length = 150)
	public String getRemarks() {
		return remarks;
	}
	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}
	public User(int id, String name, String password, String mail,
			String phoneNumber, Date createdatetime, Date modifydatetime,
			String remarks) {
		super();
		this.id = id;
		this.name = name;
		this.password = password;
		this.mail = mail;
		this.phoneNumber = phoneNumber;
		this.createdatetime = createdatetime;
		this.modifydatetime = modifydatetime;
		this.remarks = remarks;
	}
	public User() {
	}
	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
    @Column(name = "ID", unique = true, nullable = false, length = 10)
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	@Column(name = "NAME",nullable = false, length = 100)
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	 @Column(name = "PWD", nullable = false, length = 32)
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	@Column(name = "MAIL",unique = true, nullable = false, length = 100)
	public String getMail() {
		return mail;
	}
	public void setMail(String mail) {
		this.mail = mail;
	}
	@Column(name = "PHONENUMBER",length = 100)
	public String getPhoneNumber() {
		return phoneNumber;
	}
	public void setPhoneNumber(String phoneNumber) {
		this.phoneNumber = phoneNumber;
	}
	@Temporal(TemporalType.TIMESTAMP)
    @Column(name = "CREATEDATE", length = 7)
	public Date getCreatedatetime() {
		return createdatetime;
	}
	public void setCreatedatetime(Date createdatetime) {
		this.createdatetime = createdatetime;
	}
	@Temporal(TemporalType.TIMESTAMP)
    @Column(name = "MODIFYDATE", length = 7)
	public Date getModifydatetime() {
		return modifydatetime;
	}
	public void setModifydatetime(Date modifydatetime) {
		this.modifydatetime = modifydatetime;
	}
	public User(int id, String name, String password, String mail,
			String phoneNumber, Date createdatetime, Date modifydatetime) {
		super();
		this.id = id;
		this.name = name;
		this.password = password;
		this.mail = mail;
		this.phoneNumber = phoneNumber;
		this.createdatetime = createdatetime;
		this.modifydatetime = modifydatetime;
	}
    
    
	

}
